package com.lcf;

import com.lcf.context.ClassPathXmlApplicationContext;
import com.lcf.service.UserService;

/**
 * Created by lancf on 2019/5/14.
 */
public class TestIocXml {

    public static void main(String[] args) throws Exception {

        ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext("spring.xml");
        UserService userService = (UserService) context.getBean("userService");
        userService.add();
    }
}
